﻿using System.Windows;

namespace FESSC_WORKBENCH
{
    public static class AppVar
    {
        public static ECLogger.Logger log
        {
            get { return (Application.Current as App).log; }
            set { (Application.Current as App).log = value; }
        }

        public static MQWorker mqworker
        {
            get { return (Application.Current as App).mqworker; }
            set { (Application.Current as App).mqworker = value; }
        }

        public static ECMessageQueue.MQClient mqclient
        {
            get { return (Application.Current as App).mqclient; }
            set { (Application.Current as App).mqclient = value; }
        }
        public static string token
        {
            get { return (Application.Current as App).token; }
            set { (Application.Current as App).token = value; }
        }
        public static string uid
        {
            get { return (Application.Current as App).uid; }
            set { (Application.Current as App).uid = value; }
        }
        public static OperationDict opDict
        {
            get { return (Application.Current as App).opDict; }
            set { (Application.Current as App).opDict = value; }
        }
        public static LoginDialog loginDialog
        {
            get { return (Application.Current as App).loginDialog; }
            set { (Application.Current as App).loginDialog = value; }
        }
        public static Window mainwnd
        {
            get { return Application.Current.MainWindow; }
        }
        public static App.UserInfo userinfo
        {
            get { return (Application.Current as App).userinfo; }
            set { (Application.Current as App).userinfo = value; }
        }
    }
}
